import fetch from '@/api'
// 获取账页列表
export function getGateRegister(params) {
    return fetch({
        method: 'get',
        url: `/warehouseGateRegister`,
        params,
    })
}

// 进闸登记
export function enterGateRegister(data) {
    return fetch({
        method:'post',
        url:`/warehouseGateRegister`,
        data,
    })
}

// 进闸登记列表
export function getGateRegisterLists(params) {
    return fetch({
        method:'get',
        url:`warehouseGateRegister/lists`,
        params,
    })
}

//详情
export function getGateDetail(id) {
    return fetch({
        method:'get',
        url:`/warehouseGateRegister/${id}`
    })
}

//交接单明细
export function getAcceptDetail(params) {
    return fetch({
        method:'get',
        url:`/accept/get/inStorage`,
        params
    })
}

// 出闸登记
export function outGateRegister(id,data) {
    return fetch({
        method:'put',
        url:`/warehouseGateRegister/${id}`,
        data,
    })
}

// 补卡
export function bindIcCard(id,data) {
    return fetch({
        method:'put',
        url:`/warehouseGateRegister/${id}/bindIcCard`,
        data,
    })
}

// 放行
export function passGateRegister(id,data) {
    return fetch({
        method:'put',
        url:`/warehouseGateRegister/${id}/pass`,
        data,
    })
}